package com.cweb.admin.model.sys.sys_role_to_menu.entity;

import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.cweb.framework.base.entity.BaseMybatisModel;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * 系统-角色菜单关联表
 * @author changfan
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class SysRoleToMenu extends BaseMybatisModel {

    private static final long serialVersionUID=1L;

    /**
     * 角色id
     */
    @TableId(value = "role_id")
    private Long roleId;

    /**
     * 权限id
     */
    @TableField(value = "`menu_id`")
    private Long menuId;


    @Override
    protected Serializable pkVal() {
        return this.roleId;
    }

}
